home *** CD-ROM | disk | FTP | other *** search
- on oldidle
- global mycolor, kingcolor, splotx, sploty
- if the machineType < 256 then
- exit
- end if
- if mycolor > 0 then
- set splotx to the mouseH
- set sploty to the mouseV
- set the locH of sprite 48 to splotx
- set the locV of sprite 48 to sploty
- updateStage()
- cursor(200)
- end if
- end
-
- on setcolor snum, col
- global colpal, BugColorKey, BugColors, pal
- if col = 0 then
- set newcolor to 0
- else
- set newcolor to getAt(colpal, col)
- end if
- if (col < 11) and ((snum > 13) and (snum < 37)) then
- if col = 0 then
- setAt(BugColors, snum - 13, 0)
- else
- set xx to getPos(pal, col)
- set correctcol to getAt(BugColorKey, snum - 13)
- if not (getAt(BugColors, snum - 13) = 1) then
- if not (correctcol = xx) then
- setAt(BugColors, snum - 13, 2)
- else
- setAt(BugColors, snum - 13, 1)
- end if
- else
- set newcolor to getAt(colpal, getAt(pal, correctcol))
- end if
- end if
- end if
- set the ink of sprite snum to 8
- set the foreColor of sprite snum to newcolor
- set the backColor of sprite snum to newcolor
- if col <> 11 then
- updateStage()
- end if
- end
-
- on startMovie
- global gamefourlevel, colpal, level1, book, template, tinc, buglist, bucketcol, NumofCol, ChipList, NameList, masterlist, correctanim, wronganim, waittime, introplayed, cansounds, canclicked, mycolor, colorcrsr
- set mycolor to 0
- set introplayed to 0
- setmaster()
- set waittime to 4
- set bucketcol to []
- set ChipList to []
- set NameList to []
- set cansounds to []
- repeat with xxx = 1 to 10
- add(ChipList, the number of cast ("chip" & xxx))
- add(NameList, the number of cast ("co" & xxx))
- add(cansounds, "can" & xxx & "sound")
- end repeat
- if gamefourlevel = 0 then
- set gamefourlevel to 1
- end if
- if not (the machineType = 256) and not objectp(colorcrsr) then
- set colorcrsr to colorcursor(mnew)
- end if
- if the machineType = 256 then
- cursor([the number of cast "cursing", the number of cast "cursing mask"])
- end if
- set correctanim to [1, 2, 3, 4]
- set buglist to [1, 2, 3, 4, 5, 6, 7, 8, 9]
- if level1 = 1 then
- set wronganim to [1, 2, 3, 4]
- else
- set wronganim to [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
- end if
- set canclicked to [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
- set tinc to 1
- set template to 254
- set book to 1
- set level1 to gamefourlevel
- set stemp to the text of cast "colpal"
- set colpal to []
- repeat with xxx = 1 to the number of items in stemp
- add(colpal, value(item xxx of stemp))
- end repeat
- end
-
- on stopMovie
- global colorcrsr
- if not (the machineType = 256) and objectp(colorcrsr) then
- colorcrsr(mReleaseCursor)
- if objectp(colorcrsr) then
- colorcrsr(mdispose)
- end if
- end if
- repeat with xxx = 1 to 48
- set the visible of sprite xxx to 1
- end repeat
- end
-
- on setbug param
- global book, mycolor, level1
- puppetSprite(1, 1)
- puppetSprite(12, 1)
- set mycolor to 0
- set book to param
- unpuppetall()
- if level1 > 4 then
- go("level 3")
- else
- go("main")
- end if
- end
-
- on setlevel param
- global level1, mycolor
- puppetSprite(1, 1)
- puppetSprite(12, 1)
- set mycolor to 0
- set level1 to param + 2
- unpuppetall()
- if level1 > 4 then
- go("level 3")
- else
- go("main")
- end if
- end
-
- on unpuppetall
- repeat with xxx = 1 to 48
- puppetSprite(xxx, 0)
- end repeat
- end
-
- on checkcolor spritenum, colornum
- global BugColors, pal
- set dcolor to getPos(pal, colornum)
- set colorstatus to getAt(BugColors, spritenum - 13)
- return colorstatus
- end
-
- on IsPictFinished
- global BugColors
- set ColSize to count(BugColors)
- set total to 1
- repeat with xxx = 1 to ColSize
- set total to total * getAt(BugColors, xxx)
- end repeat
- return total
- end
-
- on resetgame
- global cursorset, colorcrsr
- if not (the machineType = 256) and objectp(colorcrsr) then
- colorcrsr(mReleaseCursor)
- colorcrsr(mdispose)
- cursor(4)
- cursor(-1)
- set colorcrsr to colorcursor(mnew)
- end if
- set cursorset to 0
- end
-
- on setmaster
- global masterlist, mastercounter
- set masterlist to [[[505, 0, 0], [506, 0, 0], [507, 0, 0], [508, 0, 0], [508, 0, 0], [509, 0, 0], [510, 0, 0], [511, 0, 0]], [[512, 0, 0], [513, 0, 0], [514, 0, 0], [515, 0, 0], [516, 1, 0]], [[517, 0, 0], [518, 1, 1], [519, 1, 0], [518, 1, 1], [519, 1, 0]], [[520, 0, 0], [521, 0, 0], [522, 0, 0], [523, 0, 0], [524, -1, 0], [524, -1, 0], [523, 0, 0], [522, 0, 0], [521, 0, 0], [520, 0, 0]], [[525, 0, 0], [526, 6, 3], [527, 24, 10], [526, 6, 3], [525, 0, 0], [528, -11, 2], [529, -28, 7]], [[530, 0, 0], [532, -1, -28], [533, -1, -28], [534, -1, -28], [531, -1, -28], [532, -1, -28], [533, -1, -28], [534, -1, -28], [531, -1, -28], [532, -1, -28], [533, -1, -28], [534, -1, -28], [531, -1, -28], [532, -1, -28], [533, -1, -28], [534, -1, -28], [530, 0, 0], [530, 0, 0]], [[535, 0, 0], [536, 0, 1], [537, 1, 3], [536, 0, 1], [535, 0, 0], [536, 0, 1], [537, 1, 3], [536, 0, 1], [535, 0, 0], [536, 0, 1], [537, 1, 3], [536, 0, 1], [535, 0, 0]], [[538, 0, 0], [539, 1, 0], [539, 1, 0], [538, 0, 0], [539, 1, 0], [539, 1, 0], [538, 0, 0], [539, 1, 0], [539, 1, 0]], [[542, 0, 0], [541, -2, 1], [543, 1, 0], [541, -2, 1]], [[544, 0, 0], [545, 1, 1], [544, 0, 0], [545, 1, 1], [544, 0, 0], [545, 1, 1]], [[546, 0, 0], [547, 0, 0], [548, 0, 1], [549, 0, 1], [550, 0, 1], [551, 0, 1], [552, 0, 1], [547, 0, 0], [548, 0, 1], [549, 0, 1], [550, 0, 1], [551, 0, 1], [552, 0, 1]], [[553, 0, 0], [554, 0, 0], [555, 0, 0], [556, 0, 0], [557, 0, 0], [553, 0, 0], [554, 0, 0], [555, 0, 0], [556, 0, 0], [557, 0, 0], [553, 0, 0]], [[558, 0, 0], [559, 1, 0], [560, 0, 0], [559, 1, 0], [560, 0, 0], [559, 1, 0], [560, 0, 0], [559, 1, 0], [560, 0, 0]], [[561, 0, 0], [562, 0, 0], [563, 0, 0], [564, 0, 0], [565, 0, 0], [564, 0, 0], [563, 0, 0], [562, 0, 0], [561, 0, 0], [561, 0, 0], [562, 0, 0], [563, 0, 0], [564, 0, 0], [565, 0, 0], [565, 0, 0], [565, 0, 0], [565, 0, 0], [565, 0, 0]], [[566, 0, 0], [567, 8, 3], [568, 17, 7], [568, 17, 7], [567, 8, 3], [566, 0, 0], [569, -11, 3], [570, -24, 6], [569, -11, 3], [566, 0, 0], [567, 8, 3], [568, 17, 7], [568, 17, 7], [567, 8, 3]], [[571, 0, 0], [573, 0, -19], [574, 0, -19], [575, 0, -19], [572, 0, -19], [573, 0, -19], [574, 0, -19], [575, 0, -19], [572, 0, -19], [573, 0, -19], [574, 0, -19], [575, 0, -19], [572, 0, -19]], [[576, 0, 0], [577, 0, 1], [578, 1, 0], [577, 0, 1], [576, 0, 0], [577, 0, 1], [578, 1, 0], [577, 0, 1], [576, 0, 0], [577, 0, 1], [578, 1, 0], [577, 0, 1], [576, 0, 0], [577, 0, 1], [578, 1, 0], [577, 0, 1], [576, 0, 0]], [[579, 0, 0], [580, 0, -2], [581, 1, -1], [581, 1, -1], [580, 0, -2]], [[582, 0, 0], [584, 1, -18], [583, 0, -19], [585, 1, -18], [583, 0, -19]], [[586, 0, 0], [587, -1, 1], [588, -1, 3], [587, -1, 1], [586, 0, 0], [587, -1, 1], [588, -1, 3], [587, -1, 1], [586, 0, 0], [587, -1, 1], [588, -1, 3], [587, -1, 1], [586, 0, 0]], [[590, 0, 0], [590, 0, 0], [591, 0, 0], [591, 0, 0], [592, 0, -3], [592, 0, -3], [593, 0, -4], [593, 0, -4], [589, 0, 0]], [[589, 0, 0], [589, 0, 0]], [[594, 0, 0], [594, 0, 0], [595, 0, 3], [595, 0, 3]], [[596, 0, 0], [596, 0, 0], [597, 0, 0], [597, 0, 0], [596, 0, 0], [596, 0, 0], [597, 0, 0], [597, 0, 0], [596, 0, 0], [596, 0, 0], [597, 0, 0], [597, 0, 0], [596, 0, 0], [596, 0, 0]], [[598, 0, 0], [598, 0, 0], [599, 0, 0], [599, 0, 0], [600, 0, 0], [600, 0, 0], [600, 0, 0], [600, 0, 0], [601, 0, 0], [601, 0, 0]], [[602, 0, 0], [602, 0, 0], [603, 0, 0], [603, 0, 0], [604, 0, 0], [604, 0, 0], [603, 0, 0], [603, 0, 0], [602, 0, 0], [602, 0, 0]]]
- set mastercounter to [8, 5, 5, 10, 7, 18, 13, 9, 4, 6, 13, 11, 9, 18, 14, 13, 17, 5, 5, 13, 9, 2, 4, 14, 10, 10]
- preLoadCast(505, 588)
- end
-